home *** CD-ROM | disk | FTP | other *** search
/ Chip 2007 January, February, March & April / Chip-Cover-CD-2007-02.iso / Pakiet bezpieczenstwa / mini Pentoo LiveCD 2006.1 / mpentoo-2006.1.iso / livecd.squashfs / usr / lib / mozilla-firefox / include / plugin / nsIPluginInstancePeer2.h < prev    next >
C/C++ Source or Header  |  2006-05-08  |  4KB  |  140 lines

  1. /*
  2.  * DO NOT EDIT.  THIS FILE IS GENERATED FROM nsIPluginInstancePeer2.idl
  3.  */
  4.  
  5. #ifndef __gen_nsIPluginInstancePeer2_h__
  6. #define __gen_nsIPluginInstancePeer2_h__
  7.  
  8.  
  9. #ifndef __gen_nsIPluginInstancePeer_h__
  10. #include "nsIPluginInstancePeer.h"
  11. #endif
  12.  
  13. /* For IDL files that don't want to include root IDL files. */
  14. #ifndef NS_NO_VTABLE
  15. #define NS_NO_VTABLE
  16. #endif
  17. struct JSObject;
  18. struct JSContext;
  19.  
  20. /* starting interface:    nsIPluginInstancePeer2 */
  21. #define NS_IPLUGININSTANCEPEER2_IID_STR "e7d48c00-e1f1-11d2-8360-fbc8abc4ae7c"
  22.  
  23. #define NS_IPLUGININSTANCEPEER2_IID \
  24.   {0xe7d48c00, 0xe1f1, 0x11d2, \
  25.     { 0x83, 0x60, 0xfb, 0xc8, 0xab, 0xc4, 0xae, 0x7c }}
  26.  
  27. /**
  28.  * The nsIPluginInstancePeer2 interface extends the nsIPluginInstancePeer
  29.  * interface, providing access to functionality provided by newer browsers.
  30.  * All functionality in nsIPluginInstancePeer can be mapped to the 4.X
  31.  * plugin API.
  32.  */
  33. class NS_NO_VTABLE nsIPluginInstancePeer2 : public nsIPluginInstancePeer {
  34.  public: 
  35.  
  36.   NS_DEFINE_STATIC_IID_ACCESSOR(NS_IPLUGININSTANCEPEER2_IID)
  37.  
  38.   /**
  39.      * Get the JavaScript window object corresponding to this plugin instance.
  40.      *
  41.    * @param aJSWindow - the resulting JavaScript window object
  42.    * @result          - NS_OK if this operation was successful
  43.      */
  44.   /* readonly attribute JSObjectPtr JSWindow; */
  45.   NS_IMETHOD GetJSWindow(JSObject * *aJSWindow) = 0;
  46.  
  47.   /**
  48.      * Get the JavaScript execution thread corresponding to this plugin instance.
  49.      *
  50.    * @param aJSThread - the resulting JavaScript thread id
  51.    * @result            - NS_OK if this operation was successful
  52.      */
  53.   /* readonly attribute unsigned long JSThread; */
  54.   NS_IMETHOD GetJSThread(PRUint32 *aJSThread) = 0;
  55.  
  56.   /**
  57.      * Get the JavaScript context to this plugin instance.
  58.      *
  59.    * @param aJSContext - the resulting JavaScript context
  60.    * @result           - NS_OK if this operation was successful
  61.      */
  62.   /* readonly attribute JSContextPtr JSContext; */
  63.   NS_IMETHOD GetJSContext(JSContext * *aJSContext) = 0;
  64.  
  65. };
  66.  
  67. /* Use this macro when declaring classes that implement this interface. */
  68. #define NS_DECL_NSIPLUGININSTANCEPEER2 \
  69.   NS_IMETHOD GetJSWindow(JSObject * *aJSWindow); \
  70.   NS_IMETHOD GetJSThread(PRUint32 *aJSThread); \
  71.   NS_IMETHOD GetJSContext(JSContext * *aJSContext); 
  72.  
  73. /* Use this macro to declare functions that forward the behavior of this interface to another object. */
  74. #define NS_FORWARD_NSIPLUGININSTANCEPEER2(_to) \
  75.   NS_IMETHOD GetJSWindow(JSObject * *aJSWindow) { return _to GetJSWindow(aJSWindow); } \
  76.   NS_IMETHOD GetJSThread(PRUint32 *aJSThread) { return _to GetJSThread(aJSThread); } \
  77.   NS_IMETHOD GetJSContext(JSContext * *aJSContext) { return _to GetJSContext(aJSContext); } 
  78.  
  79. /* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
  80. #define NS_FORWARD_SAFE_NSIPLUGININSTANCEPEER2(_to) \
  81.   NS_IMETHOD GetJSWindow(JSObject * *aJSWindow) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetJSWindow(aJSWindow); } \
  82.   NS_IMETHOD GetJSThread(PRUint32 *aJSThread) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetJSThread(aJSThread); } \
  83.   NS_IMETHOD GetJSContext(JSContext * *aJSContext) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetJSContext(aJSContext); } 
  84.  
  85. #if 0
  86. /* Use the code below as a template for the implementation class for this interface. */
  87.  
  88. /* Header file */
  89. class nsPluginInstancePeer2 : public nsIPluginInstancePeer2
  90. {
  91. public:
  92.   NS_DECL_ISUPPORTS
  93.   NS_DECL_NSIPLUGININSTANCEPEER2
  94.  
  95.   nsPluginInstancePeer2();
  96.  
  97. private:
  98.   ~nsPluginInstancePeer2();
  99.  
  100. protected:
  101.   /* additional members */
  102. };
  103.  
  104. /* Implementation file */
  105. NS_IMPL_ISUPPORTS1(nsPluginInstancePeer2, nsIPluginInstancePeer2)
  106.  
  107. nsPluginInstancePeer2::nsPluginInstancePeer2()
  108. {
  109.   /* member initializers and constructor code */
  110. }
  111.  
  112. nsPluginInstancePeer2::~nsPluginInstancePeer2()
  113. {
  114.   /* destructor code */
  115. }
  116.  
  117. /* readonly attribute JSObjectPtr JSWindow; */
  118. NS_IMETHODIMP nsPluginInstancePeer2::GetJSWindow(JSObject * *aJSWindow)
  119. {
  120.     return NS_ERROR_NOT_IMPLEMENTED;
  121. }
  122.  
  123. /* readonly attribute unsigned long JSThread; */
  124. NS_IMETHODIMP nsPluginInstancePeer2::GetJSThread(PRUint32 *aJSThread)
  125. {
  126.     return NS_ERROR_NOT_IMPLEMENTED;
  127. }
  128.  
  129. /* readonly attribute JSContextPtr JSContext; */
  130. NS_IMETHODIMP nsPluginInstancePeer2::GetJSContext(JSContext * *aJSContext)
  131. {
  132.     return NS_ERROR_NOT_IMPLEMENTED;
  133. }
  134.  
  135. /* End of implementation class template. */
  136. #endif
  137.  
  138.  
  139. #endif /* __gen_nsIPluginInstancePeer2_h__ */
  140.